<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<link rel="stylesheet" type="text/css" href="../css/common.css?01_38" />
		<link rel="stylesheet" type="text/css" href="../css/templet.css?01_38" />
		<link rel="stylesheet" type="text/css" href="../fonts/font-awesome.min.css?01_38" />
		<link rel="stylesheet" type="text/css" href="../mui/css/mui.css?01_38" />
		<!--公共js-->
		<script type="text/javascript" src="../common/js/jquery.js?01_38"></script>
		<script type="text/javascript" src="../common/js/fastclick.js?01_38"></script>
		
		<!--插件-->
		<script type="text/javascript" src="../common/js/vue.min.js?01_38"></script>
		<script type="text/javascript" src="../common/js/jquery.js?01_38"></script>
		<script type="text/javascript" src="../common/js/mui.min.js?01_38"></script>
		
		<script type="text/javascript" src="../common/js/common.js?01_38"></script>
		<script type="text/javascript" src="../common/js/my_common.js?01_38"></script>
		<script type="text/javascript" src="../common/js/main.js?01_38"></script>
		<script type="text/javascript" src="../common/js/app.js?01_38"></script>
		<style>
			.go {
				text-align: center;
				width: 100px;
				background: #fd5749;
				color: white;
				border-radius: 10px;
				padding: 10px 0px;
				margin: auto;
				margin-top: 25px;
			}
		</style>
	</head>

	<body>
		<header class="bg-red9 fff f-20 pad-t-10 pad-b-10 pad-l-10 pad-r-10">
			<div class="pa back" onclick="back()">
				<a></a>
			</div>
			<div class="center" data-l="1073"></div>
		</header>
		<div id="app" class="wrap_body language_setting" v-cloak>
			<div class="content pad-t-45">

				<div class="item btn_c">
					<div class="bank5"></div>
					<dl class="fiex bg-fff pad-l-15 pad-r-20 pad-t-20 pad-b-20 f-15">
						<dd>中文</dd>
						<dt class="fiex1 cf"><div class="wrap fr pr"><div data-lange="zh" class="in bg-red9 pa"></div></div></dt>
					</dl>
				</div>

				<div class="item btn_c">
					<div class="bank5"></div>
					<dl class="fiex bg-fff pad-l-15 pad-r-20 pad-t-20 pad-b-20 f-15">
						<dd>English</dd>
						<dt class="fiex1 cf"><div class="wrap fr pr"><div data-lange="en" class="in bg-red9 pa"></div></div></dt>
					</dl>
				</div>

				<div class="item btn_c">
					<div class="bank5"></div>
					<dl class="fiex bg-fff pad-l-15 pad-r-20 pad-t-20 pad-b-20 f-15">
						<dd>Melayu</dd>
						<dt class="fiex1 cf">
							<div class="wrap fr pr"><div data-lange="ms" class="in bg-red9 pa "></div></div>
						</dt>
					</dl>
				</div>
				<div @click="sub_cli()" class="go">{{b_lg[1190]}}</div>

			</div>
		</div>
		<script>
			function fun1() {
				setlange_obj(); //加载头部语言包
				var app = new Vue({
					el: '#app',
					data: {
						b_lg: global_lange //语言包
					},
					methods: {
						sub_cli: function() {
							var la = $(".item dt").find(".checked").attr("data-lange")
							lang(la, function() {
								if(isAPP) { //提交信息成功后将父级的信息进行刷新
									setItem("lg", la)
									setItem("shop_ver", -1000)
									var preUrl = plus.webview.currentWebview().opener();
									preUrl.evalJS('refresh()')
									common_ajax("1", {}, "init_shop_info", function(h2) {
										if(h2.status == 1) {
											setItem("beizhu_json", JSON.stringify(h2.result.beizhu));
											mui.toast(h2.msg)
											app.back()
										} else {
											mui.toast(h2.msg)
										}

									})
									setTimeout(function() {
										back()
									}, 500)
								} else {
									common_ajax("1", {}, "init_shop_info", function(h2) {
										if(h2.status == 1) {
											setItem("lg", la)
											setItem("beizhu_json", JSON.stringify(h2.result.beizhu));
											mui.toast(h2.msg)
											back()
										} else {
											mui.toast(h2.msg)
										}

									})

								}
							})
						},
						back: function() {
							if(isAPP) {
								var preUrl = plus.webview.currentWebview().opener();
								preUrl.evalJS('admin_btn()');
							}
							setTimeout(function() {
								back()
							}, 400)
						}
					}
				})
				$(".item dt div[data-lange=" + getItem("lg") + "]").addClass("checked");
				$(".item").on("click", function() {
					$(".item dt div").removeClass("checked");
					$(this).find('.bg-red9').addClass("checked");
				})
			}
		</script>
	</body>

</html>
